// 导入封装后的axios
import axios from './request'

// 一个接口封装成一个函数
function user_login( params = {}){
    return axios.post('/api/user/login',params);
}
function user_register( params = {}){
    return axios.post('/api/user/register',params);
}
function role_list( params = {}){
    return axios.get('/api/role/list',params);
}
function business_add( params = {} ){
    return axios.post('/api/business/add',params);
}
function business_list( params = {} ){
    return axios.get('/api/business/list',{params});
}
function business_delete( params = {} ){
    return axios.post('/api/business/delete',params);
}

//...

// 导出所有函数
export {
    user_login,
    user_register,
    role_list,
    business_add,
    business_list,
    business_delete
}